home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Cl…Business) - New Member 21 / Software of the Month Club XXI - New Member Business.ISO / mac / Business / Financial Portfolio v4.1 ƒ / Financial Portfolio v4.1 / Financial Portfolio v4.1.rsrc / LENS_158_File Paths.bin < prev    next >
Text File  |  1995-11-23  |  3KB  |  76 lines

  1. ItemType: WIND
  2. Rect: 203,283,505,499
  3. AutoSize: FALSE
  4. Style: Dialog
  5. HasTitleBar: TRUE
  6. HasZoomBox: FALSE
  7. Name: File Paths
  8. Script: if objValue="Open" then ┬  wsSet wdID,"typePop","SelectionText", "Import balances"┬  wsSet wdID,"path","Text",cd fld pathField("Import balances")┬  get wsGet(wdID,"path","Text")┬  if it¡empty then┬    wsSet wdID,"View╔","Disabled", "false"┬  else┬    wsSet wdID,"View╔","Disabled", "true"┬  end if┬end if
  9. Params: i0_TopLeft
  10.  
  11. ItemType: PUSH
  12. Rect: 218,113,290,133
  13. Name: Done
  14. DefaultItem: TRUE
  15. AutoClose: TRUE
  16.  
  17. ItemType: TEXT
  18. Rect: 12,147,292,211
  19. TextFont: Geneva
  20. TextSize: 10
  21. AutoSize: FALSE
  22. Name: Title
  23. Text: Choose the type of import/export from the pop-up menu to see its stored file path, if any. Click ╥Clear╙ to erase a path (prompting an open/save dialog box the next time you perform the task) or ╥Store╔╙ to select and remember a new path for future uses.
  24.  
  25. ItemType: TEXT
  26. Rect: 60,31,294,95
  27. TextFont: Geneva
  28. TextSize: 10
  29. AutoSize: FALSE
  30. Name: path
  31. Scrolling: TRUE
  32.  
  33. ItemType: PUSH
  34. Rect: 116,113,196,133
  35. Name: Store╔
  36. Script: --on mouseUp  wdID,wdName,objNo,objName,objValue┬get wsGet(wdID,"typePop","SelectionText")┬put it into type┬if "import" is in type then┬  put "Locate the text file to import from╔" into qq┬  answer file qq of type text┬else┬  put "Save the data as╔" into qq┬  ask file qq┬end if┬put the result into resultCode┬if resultCode is empty then┬  put it into filer┬  put pathField(type) into theField┬  wsSet wdID,"path","Text",filer┬  put filer into cd fld theField┬end if┬┬get wsGet(wdID,"path","Text")┬if it¡empty then┬  wsSet wdID,"View╔","Disabled","false"┬else┬  wsSet wdID,"View╔","Disabled","true"┬end if┬--end mouseUp┬┬
  37.  
  38. ItemType: PUSH
  39. Rect: 14,113,94,133
  40. Name: Clear
  41. Script: get wsGet(wdID,"typePop","SelectionText")┬put empty into cd fld pathField(it)┬wsSet wdID,"path","Text",""┬get wsGet(wdID,"path","Text")┬wsSet wdID,"View╔","Disabled","true"┬
  42.  
  43. ItemType: POP
  44. Rect: 84,4,222,20
  45. TextFont: Geneva
  46. TextSize: 10
  47. AutoSize: FALSE
  48. Name: typePop
  49. Text: Import balances┬Import stock prices┬Export balances┬Export report┬Export stock prices
  50. Script: get wsGet(wdID,"typePop","SelectionText")┬wsSet wdID,"path","Text",cd fld pathField(it)┬get wsGet(wdID,"path","Text")┬if it¡empty then┬  wsSet wdID,"View╔","Disabled", "false"┬else┬  wsSet wdID,"View╔","Disabled", "true"┬end if┬┬┬
  51.  
  52. ItemType: TEXT
  53. Rect: 7,5,82,18
  54. TextFont: Geneva
  55. TextSize: 10
  56. Name: popLabel
  57. TextStyle: Bold
  58. TextAlign: Right
  59. Text: Choose type:
  60.  
  61. ItemType: TEXT
  62. Rect: 7,32,57,58
  63. TextFont: Geneva
  64. TextSize: 10
  65. Name: pathLabel
  66. TextAlign: Right
  67. Text: File path:
  68.  
  69. ItemType: PUSH
  70. Rect: 14,50,54,67
  71. TextFont: Geneva
  72. TextSize: 10
  73. AutoSize: FALSE
  74. Disabled: TRUE
  75. Name: View╔
  76. Script: --on mouseUp  wdID,wdName,objNo,objName,objValue┬get wsGet(wdID,"path","Text")┬put it into filer┬if there is a file filer then┬  set cursor to watch┬  open file filer┬  repeat┬    read from file filer for 20000┬    if it=empty then exit repeat┬    put it into theData┬  end repeat┬  close file filer┬  get WindowScript("View File",wstl(480,180),theData)┬else┬  errorAns("That text file is no longer at this location. Click ╥Store╔╙ to relocate it.")┬end if┬┬--end mouseUp